// vuex最核心的管理对象
import Vuex from 'vuex'
import Vue from 'vue'
import home from '@/store/moudules/home'
import user from '@/store/moudules/user'
// import { mutations,getters,actions } from 'vuex'


Vue.use(Vuex)

const mutations={
    xxx(state){}  //这个state是全局的state
}
const actions ={
    yyy({commit}){}
}
const getters={
    zzz(state){}
}

export default new Vuex.Store({
   
    mutations,
    actions,
    getters,
    modules:{
        home,//引入home组件
        user
    }
})